<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" Content="text-html; charset=Windows-1252">

<!--This is the control I'm calling TextPopup from-->
<OBJECT
  id=popup type="application/x-oleobject"
  classid="clsid:adb880a6-d8ff-11cf-9377-00aa003b7a11"
  width=10
  height=10
>
</OBJECT>

<!--This is a reference to the external file that contains the text for all pop-up windows-->
<SCRIPT Language=JavaScript
SRC="terms.js">
</SCRIPT>

<title>To create a hyperlink to open the pop-up window</title>
<style>@import url(coUA.css);</style>
<link disabled rel="stylesheet" href="htmlhelp.css">
</HEAD>

<BODY>
<h1>To create a hyperlink to open the pop-up window</h1>

<ul>
<li>Copy the following code in your HTML file to call the TextPopup method of the HTML Help ActiveX control:

<p><code>
&lt;A HREF=&quot;JavaScript:<i>popup</i>.TextPopup(<i>text_variable</i>, <i>font_variable</i>,9,9,-1,-1)&quot;&gt;<i>Click Here</i>&lt;/a&gt;
</code>
<p>where <i>popup</i> is the ID you specified in <a href="ocx_scripts_popup2.htm">step 2</a>,
<i>text_variable</i> and <i>font_variable</i> are the variable names you specified in <a href="ocx_scripts_popup1.htm">step 1</a>,
the numeric values are the left and right margins (9,9) and the foreground and background colors (-1, -1) of the window, 
and <i>Click Here</i> is the link text.</p> </li>
</li>
</ul>

<h3>Example</h3>
<p>The following example references the HTML Help ActiveX control whose ID is <code>popup</code> and displays the text variable <code>MyText</code> and the font variable <code>MyFont</code>:</p>

<code>
&lt;A HREF=JavaScript:popup.TextPopup(MyText,MyFont,9,9,-1,-1)&gt;<br>
Click to see a pop-up window.&lt;/A&gt;<br>
</code>

<p>A sample of the resulting link is shown below:</p>

<table border="5" cellspacing="0" cellpadding="5" bgcolor="#C0C0C0">
<tr>
<td valign="top">
<A HREF="JavaScript:popup.TextPopup(MyText,MyFont,9,9,-1,-1)">Click to see a pop-up window</a>
</td>
</tr>
</table>

<h3>Notes</h3>
<ul>
<li>You do not have to create a text link to call <b>TextPopup</b>. You can also use a script to call it.</li>
</ul>


<br>
<table border="0" cellpadding="0" cellspacing="0">
<tr>
<td valign="top"><a href="ocx_scripts_popup.htm"><img src="bkarrow.gif" alt="back to the beginning" border="0"></a>
</td>
<td><a href="ocx_scripts_popup.htm">Back to the beginning</A>
</td>
</tr>

<tr>
<td>&nbsp;</td>
</tr>

<tr>
<td valign="top"><a href="ocx_scripts.htm"><img src="home.gif" alt="link to overview topic" border="0"></a>
</td>
<td><a href="ocx_scripts.htm">About the script and DHTML examples</A>
</td>
</tr>

<tr><td>&nbsp;</td>
</tr>
</table>
</BODY>
</HTML>
